-
-
Notifications
You must be signed in to change notification settings - Fork 189
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Hide locations swap icon when fields are empty #895
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks for this!
As discussed in #733 (comment) I'm still not convinced that removing the icon button completely is the right thing to do. Especially because there is another icon left of it that might jump around.
In any case I would postpone this fix until after the release.
app/src/main/java/de/grobox/transportr/trips/search/DirectionsFragment.kt
Outdated
Show resolved
Hide resolved
Oh yes this would make sense, so preferably just disable this button right? |
…Fragment.kt Co-authored-by: ialokim <[email protected]>
Yes, but "just" disabling might not be that easy, in the last PR we didn't find a proper way of visually disabling an IconButton, iirc. |
Oh I see... Then isn't hiding a good compromise? I see for example that Trainline is also hiding their swap button https://www.thetrainline.com |
I'm mostly concerned about the favorite icon jumping around if this gets hidden. If swap is only ever hidden when favorite is hidden, too, I think I could live with it. |
I agree! |
Fixed it, now the icon isn't hidden anymore: it is disabled and greyed out. It works and looks great on my device :) I'd be happy to hear your feedback ! |
As nobody seems currently arround to review the PR, I'll merge it as it is a minimal fix and suggestions from the previous review have been applied. |
Solves #732